// src/main.js
import Vue from 'vue'
import App from './App.vue'
import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import router from './router/index.js';

const originalPush = router.push;
router.push = function push(location, onComplete, onAbort) {
  return originalPush.call(this, location, onComplete, onAbort).catch(err => {
    if (err.name !== 'NavigationDuplicated') {
      console.error(err);
    }
  });
};
Vue.use(ElementUI);
new Vue({
  router,
  render: h => h(App)
}).$mount('#app')